#pragma once

#include "BaseObject.h"
#include "ResManager.h"
#include <list>

class CMapUnit : public CBaseObject
{
public:
	CMapUnit(hgeSprite* s, int type, int row, int col);
	~CMapUnit(void);

	void DoRender();

private:
	hgeSprite*				m_MapUnit;
	int						m_MapType;
};

class CMapUnitFactory
{
public:
	static CMapUnitFactory* GetFactory();
	static void CloseFactory();
	~CMapUnitFactory(void);

	CMapUnit* CreateMapUnit(int type, int row, int col);
	inline std::list<CMapUnit* >* GetUnitList()
	{	return &m_MapUnitList;	}

private:
	CMapUnitFactory(void);
private:
	static CMapUnitFactory*			m_MapUnitFactory;
	std::list<CMapUnit* >			m_MapUnitList;
};